{% extends 'Base/main.content.lists.div.html.twig' %}
{% import 'Base/list_item.twig' as listItem %}
{% block options %}
    {#<div class="menu-list">#}
        {#{{ dump(tools) }}#}
        {#{% for key , classes in tools %}#}
            {#{% set default = "请选择分类" %}#}
            {#{% set classes = classes %}#}
            {#<div class="rule-single-select">#}
                {#<select name="cond[{{ key }}]" onchange="javascript:__doPostBack('searchCond','')" >#}
                    {#<option value="" {{app.request.get("cond")[key] is defined and app.request.get("cond")[key] == "" ? ' selected="selected"' : "" }} >{{ default }}</option>#}
                    {#{% for class in classes %}#}
                        {#<option value="{{ class.id }}"#}
                                {#{{app.request.get("cond")[key] is defined and  app.request.get("cond")[key] == class.id ? ' selected="selected"' : "" }}#}
                        {#>{{ class.name }}</option>#}
                    {#{% endfor %}#}
                {#</select>#}
            {#</div>#}
        {#{% endfor %}#}
    {#</div>#}
{% endblock %}
{% block tableHead %}
    <tr>
        <th align="" width="6%">选择</th>
        <th align="" width="">名称</th>
        {#<th align="" width="">等级</th>#}
        <th align="" width="20%">排序</th>
        {#<th align="" width="">上级</th>#}
        {#<th align="" width="">图片</th>#}
        <th align="" width="">link</th>
        <th align="" width="10%">操作</th>
    </tr>
{% endblock %}
{% block tableList %}
    {% for Entity in lists %}
        <tr>
            <td align='' width=''>
                <span class="checkall"><input lay-skin="primary" type="checkbox" name="ids[]" value="{{ Entity.GradeCategory_id }}"/></span>
            </td>
            <td align='' width='' id='name_{{ Entity.GradeCategory_id }}'>
                {{ listItem.tab(Entity.GradeCategory_level,Entity.GradeCategory_id) }}
                {{ listItem.text('name',Entity.GradeCategory_name,Entity.GradeCategory_id) }}
            </td>
            {#<td align='' width='' id='level_{{ Entity.GradeCategory_id }}'>#}
            {#{{ listItem.text('level',Entity.GradeCategory_level,Entity.GradeCategory_id) }}#}
            {#</td>#}
            <td align='' width='' id='orders_{{ Entity.GradeCategory_id }}'>
                {{ listItem.editVal('orders',Entity.GradeCategory_orders,Entity.GradeCategory_id) }}
            </td>
            {#<td align='' width='' id='parent_{{ Entity.GradeCategory_id }}'>#}
            {#{{ listItem.text('parent',Entity.GradeCategory_parent,Entity.GradeCategory_id) }}#}
            {#</td>#}
            {#<td align='' width='' id='pic_{{ Entity.GradeCategory_id }}'>#}
            {#{{ listItem.pic('pic',Entity.GradeCategory_pic,Entity.GradeCategory_id) }}#}
            {#</td>#}
            <td align='' width='' id='link_{{ Entity.GradeCategory_id }}'>
            {{ listItem.text('link',Entity.GradeCategory_link,Entity.GradeCategory_id) }}
            </td>
            <td align='' width=''>
                {{ listItem.manage('GradeCategory','',Entity.GradeCategory_id) }}
            </td>
        </tr>
    {% endfor %}
{% endblock %}
{% block script %}
{% endblock %}
